package com.iplant.ams.service.basicenum.ipt;


import com.iplant.base.po.enums.BaseEnum;

/**
 * @author YouWang·Peng
 * 2023-7-14 09:23:25
 */
public enum IPTTypes implements BaseEnum {
    /**
     * 默认
     */
    Default(0, "默认"),

    /**
     * 首巡检
     */
    Patrol(1, "首巡检"),
    /**
     * 点检
     */
    PointCheck(2, "点检"),
    /**
     * 维护
     */
    Maintain(3, "维护"),
    /**
     * 维修
     */
    Repair(4, "维修"),
    /**
     * 异常
     */
    Exception(3, "异常");

    private int value;
    private String label;
    private String remark = "";

    IPTTypes(int value, String label) {
        this.value = value;
        this.label = label;
    }

    public static IPTTypes getEnumType(int val) {
        for (IPTTypes type : IPTTypes.values()) {
            if (type.getValue() == val) {
                return type;
            }
        }
        return null;
    }

    @Override
    public int getValue() {
        return value;
    }

    @Override
    public void setValue(int value) {
        this.value = value;
    }

    @Override
    public String getLabel() {
        return label;
    }

    @Override
    public void setLabel(String label) {
        this.label = label;
    }

    @Override
    public String getRemark() {
        return remark;
    }

    @Override
    public void setRemark(String remark) {
        this.remark = remark;
    }
}
